﻿@inject DemoThemeService Themes

<a class="themeswitcher-item list-group-item list-group-item-action @Theme.GetCssClass(Themes.ActiveTheme == Theme) @Theme.IconCssClass" href="#"
   @onclick:preventDefault
   @onclick="Anchor_Click">
    <span>@Theme.Title</span>
</a>
@code {
    [Parameter] public DemoTheme Theme { get; set; }
    [Parameter] public EventCallback<DemoTheme> Click { get; set; }

    async Task Anchor_Click() {
        await Click.InvokeAsync(Theme);
    }
}
